<HTML><HEAD><TITLE>get_module_info(+Module, ?What, -Info)</TITLE>
</HEAD><BODY>[ <A HREF="index.html">Modules</A> | <A HREF="../../index.html">Reference Manual</A> | <A HREF="../../fullindex.html">Alphabetic Index</A> ]
<H1>get_module_info(+Module, ?What, -Info)</H1>
Retrieves information about a loaded module.
<DL>
<DT><EM>Module</EM></DT>
<DD>Atom.
</DD>
<DT><EM>What</EM></DT>
<DD>An atom.
</DD>
<DT><EM>Info</EM></DT>
<DD>A variable.
</DD>
</DL>
<H2>Description</H2>
   This utility can retrieve information about any module that is currently
   loaded into the system. The information that can be requested is:
<DL>
<DT><STRONG>raw_interface</STRONG> (list of export/1 and reexport/1)<DD>
	this returns a list of all the export and reexport directives that
	occurred in the definition of the module and thus comprise the module's
	interface.
<DT><STRONG>interface</STRONG> (list of export/1)<DD>
	Like raw_interface, but all reexports are replaced by the
	actual exports which result from them.
<DT><STRONG>imports</STRONG> (list of modules)<DD>
	a list of the modules that have been imported as a whole.
<DT><STRONG>locked</STRONG> (on/off)<DD>
	indicates whether the module is locked or unlocked.
</DL>

<H3>Modes and Determinism</H3><UL>
<LI>get_module_info(+, -, -) is nondet
<LI>get_module_info(+, +, -) is semidet
</UL>
<H3>Exceptions</H3>
<DL>
<DT><EM>(4) instantiation fault </EM>
<DD>Module is not instantiated.
<DT><EM>(5) type error </EM>
<DD>Module is not an atom.
<DT><EM>(80) not a module </EM>
<DD>Module is not a loaded module.
</DL>
<H2>Examples</H2>
<PRE>
[eclipse 1]: get_module_info(lists, X,Y).

X = raw_interface
Y = [export maplist / 3, export checklist / 2, ...]

X = interface
Y = [export reverse / 2, export subtract / 3, ...]

X = imports
Y = [eclipse_language]     More? (;) 

X = locked
Y = off
yes.
</PRE>
<H2>See Also</H2>
<A HREF="../../kernel/modules/import-1.html">import / 1</A>, <A HREF="../../kernel/modules/export-1.html">export / 1</A>, <A HREF="../../kernel/modules/reexport-1.html">reexport / 1</A>, <A HREF="../../lib/document/icompile-1.html">document : icompile / 1</A>, <A HREF="../../lib/document/icompile-2.html">document : icompile / 2</A>, <A HREF="../../kernel/modules/lock-0.html">lock / 0</A>, <A HREF="../../kernel/modules/lock_pass-1.html">lock_pass / 1</A>, <A HREF="../../kernel/modules/unlock-2.html">unlock / 2</A>
</BODY></HTML>
